#include <stdio.h>
#include "graph.h"

int main(void)
{
	Graph graph;

	Init(&graph);

	InsertVertex(&graph, 'A');
	InsertVertex(&graph, 'B');
	InsertVertex(&graph, 'C');
	InsertVertex(&graph, 'D');
	InsertVertex(&graph, 'E');
	Show(&graph);
	printf("\n");

	InsertEdge(&graph, 'A', 'B');
	InsertEdge(&graph, 'A', 'D');
	InsertEdge(&graph, 'B', 'C');
	InsertEdge(&graph, 'B', 'E');
	InsertEdge(&graph, 'C', 'D');
	InsertEdge(&graph, 'C', 'E');
	Show(&graph);
	printf("\n");

	RemoveEdge(&graph, 'C', 'B');
	Show(&graph);
	printf("\n");
	int i = RemoveVertex(&graph, 'C');
	Show(&graph);
	printf("\n");
	printf("%d\n", i);
	// Destory(&graph);
	int a = GetFirstNeighbor(&graph, 'A');
	printf("%d\n", a);
	a = GetNextNeighbor(&graph, 'A', 'D');
	printf("%d\n", a);

	return 0;
}
